3.2517 \(\int x^{-1-2 n} \left (a+b x^n\right ) \, dx\)

Optimal. Leaf size=25 \[ -\frac{a x^{-2 n}}{2 n}-\frac{b x^{-n}}{n} \]

[Out]

-a/(2*n*x^(2*n)) - b/(n*x^n)

_______________________________________________________________________________________

Rubi [A]  time = 0.0222497, antiderivative size = 25, normalized size of antiderivative = 1., number of steps used = 2, number of rules used = 1, integrand size = 15, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.067 \[ -\frac{a x^{-2 n}}{2 n}-\frac{b x^{-n}}{n} \]

Antiderivative was successfully verified.

[In]  Int[x^(-1 - 2*n)*(a + b*x^n),x]

[Out]

-a/(2*n*x^(2*n)) - b/(n*x^n)

_______________________________________________________________________________________

Rubi in Sympy [A]  time = 3.95813, size = 17, normalized size = 0.68 \[ - \frac{a x^{- 2 n}}{2 n} - \frac{b x^{- n}}{n} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  rubi_integrate(x**(-1-2*n)*(a+b*x**n),x)

[Out]

-a*x**(-2*n)/(2*n) - b*x**(-n)/n

_______________________________________________________________________________________

Mathematica [A]  time = 0.0106446, size = 20, normalized size = 0.8 \[ -\frac{x^{-2 n} \left (a+2 b x^n\right )}{2 n} \]

Antiderivative was successfully verified.

[In]  Integrate[x^(-1 - 2*n)*(a + b*x^n),x]

[Out]

-(a + 2*b*x^n)/(2*n*x^(2*n))

_______________________________________________________________________________________

Maple [A]  time = 0.023, size = 27, normalized size = 1.1 \[{\frac{1}{ \left ({{\rm e}^{n\ln \left ( x \right ) }} \right ) ^{2}} \left ( -{\frac{a}{2\,n}}-{\frac{b{{\rm e}^{n\ln \left ( x \right ) }}}{n}} \right ) } \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  int(x^(-1-2*n)*(a+b*x^n),x)

[Out]

(-1/2*a/n-b/n*exp(n*ln(x)))/exp(n*ln(x))^2

_______________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \[ \text{Exception raised: ValueError} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x^n + a)*x^(-2*n - 1),x, algorithm="maxima")

[Out]

Exception raised: ValueError

_______________________________________________________________________________________

Fricas [A]  time = 0.221604, size = 27, normalized size = 1.08 \[ -\frac{2 \, b x^{n} + a}{2 \, n x^{2 \, n}} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x^n + a)*x^(-2*n - 1),x, algorithm="fricas")

[Out]

-1/2*(2*b*x^n + a)/(n*x^(2*n))

_______________________________________________________________________________________

Sympy [A]  time = 16.2041, size = 24, normalized size = 0.96 \[ \begin{cases} - \frac{a x^{- 2 n}}{2 n} - \frac{b x^{- n}}{n} & \text{for}\: n \neq 0 \\\left (a + b\right ) \log{\left (x \right )} & \text{otherwise} \end{cases} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate(x**(-1-2*n)*(a+b*x**n),x)

[Out]

Piecewise((-a*x**(-2*n)/(2*n) - b*x**(-n)/n, Ne(n, 0)), ((a + b)*log(x), True))

_______________________________________________________________________________________

GIAC/XCAS [A]  time = 0.214343, size = 28, normalized size = 1.12 \[ -\frac{{\left (2 \, b e^{\left (n{\rm ln}\left (x\right )\right )} + a\right )} e^{\left (-2 \, n{\rm ln}\left (x\right )\right )}}{2 \, n} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]  integrate((b*x^n + a)*x^(-2*n - 1),x, algorithm="giac")

[Out]

-1/2*(2*b*e^(n*ln(x)) + a)*e^(-2*n*ln(x))/n